﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="Orders.aspx.cs" Inherits="Webbshop.Orders" culture="auto" meta:resourcekey="PageResource1" uiculture="auto" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <div>
        <h1><asp:Label ID="lblTitle" runat="server" Text="Beställningar" 
                meta:resourcekey="lblTitleResource1" /></h1>
        <p>
            <asp:Label ID="lblIntroduction" runat="server" 
                Text="Här kan se dina Beställningar." 
                meta:resourcekey="lblIntroductionResource1" />
        </p>
        <div>
        <div class="gridOrders">
            <asp:GridView ID="gridOrders" runat="server" 
                OnSelectedIndexChanged="gridOrders_SelectedIndexChange" 
                AutoGenerateColumns="False" meta:resourcekey="gridOrdersResource1">
                <SelectedRowStyle BackColor="#33CCFF" />
                <Columns>
                    <asp:BoundField DataField="orderId" HeaderText="Order nr" 
                        meta:resourcekey="BoundFieldResource1" />
                    <asp:BoundField DataField="userId" HeaderText="Användarnamn" 
                        meta:resourcekey="BoundFieldResource2" />
                    <asp:BoundField DataField="date" HeaderText="Datum" 
                        meta:resourcekey="BoundFieldResource3" />
                    <asp:ButtonField ButtonType="Button" HeaderText="Detaljer" CommandName="Select" 
                        Text="Visa" meta:resourcekey="ButtonFieldResource1" />
                </Columns>
            </asp:GridView>
            </div>            
        
        <div class="gridOrderDetail">
        <asp:GridView ID="DetailsView1" runat="server" 
                meta:resourcekey="DetailsView1Resource1" ShowHeaderWhenEmpty="True" 
                AutoGenerateColumns="False">
                <EmptyDataTemplate>
                    <asp:Literal ID="lblNoData" runat="server" Text="Inga Produkter funna." 
                        meta:resourcekey="lblNoDataResource1" />
                </EmptyDataTemplate>
                <Columns>
                    <asp:BoundField DataField="orderId" HeaderText="Order nr" 
                        meta:resourcekey="BoundFieldResource1" />
                    <asp:BoundField DataField="productID" HeaderText="Produkt nr" 
                        meta:resourcekey="BoundFieldResource2" />
                    <asp:BoundField DataField="amount" HeaderText="Antal" 
                        meta:resourcekey="BoundFieldResource3" />
                </Columns>
            </asp:GridView>
        </div>
        </div>
    </div>
</asp:Content>
